package org.frvi.goldspring.web.wicket.application;

import org.apache.wicket.Page;
import org.apache.wicket.authentication.AuthenticatedWebApplication;
import org.apache.wicket.authentication.AuthenticatedWebSession;
import org.apache.wicket.markup.html.WebPage;
import org.apache.wicket.protocol.http.WebApplication;
import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
import org.frvi.goldspring.web.wicket.page.GoldSpringSignInPage;
import org.frvi.goldspring.web.wicket.page.Overview;

/**
 * Created by IntelliJ IDEA.
 * User: Frank
 * Date: Oct 3, 2009
 * Time: 9:33:18 PM
 * To change this template use File | Settings | File Templates.
 */
public class GoldSpringApplication extends AuthenticatedWebApplication {
    @Override
    public Class<? extends Page> getHomePage() {
         return Overview.class;
    }

    @Override
    public void init() {
        super.init();
        addComponentInstantiationListener(new SpringComponentInjector(this));

    }

    @Override
    protected Class<? extends AuthenticatedWebSession> getWebSessionClass() {
        return GoldSpringWebSession.class;
    }

    @Override
    protected Class<? extends WebPage> getSignInPageClass() {
        return GoldSpringSignInPage.class;
    }
}
